﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;

namespace RSSReader.WebClient.Models
{
  public class UserCreationModel
  {
    [Required]
    [Display(Name = "Utilisateur")]
    [StringLength(256)]
    public string UserName { get; set; }

    [Required]
    [EmailAddress]
    [Display(Name = "Email")]
    [StringLength(256)]
    public string Email { get; set; }

    [Required]
    [DataType(DataType.Password)]
    [Display(Name = "Mot de passe")]
    [StringLength(100, MinimumLength=8)]
    public string Password { get; set; }

    [DataType(DataType.Password)]
    [Display(Name = "Confirmation")]
    [Compare("Password", ErrorMessage = "La confirmation n'est pas identique au mot de passe")]
    public string ConfirmPassword { get; set; }
  }
}